package cn.com.cifi.mars.web.action.projectConsole;

import java.util.List;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import cn.com.cifi.mars.bean.vo.workBench.AllProjectIndexVO;
import cn.com.cifi.mars.bean.vo.workBench.ProjectIndexVO;
import cn.com.cifi.mars.bean.vo.workBench.ProjectOverviewVO;
import cn.com.cifi.mars.bean.vo.workBench.ProjectUnderwayVO;
import cn.com.cifi.mars.bean.vo.workBench.ProjectVersionVO;
import cn.com.cifi.mars.common.bean.R;
import cn.com.cifi.mars.common.constants.VersionConstant;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;

/**
 * 工作台
 * @author Li
 *
 */
@Api(tags = "项目工作台API")
@RequestMapping("/${spring.data.rest.base-path}/{apiVersion}/workBench")
public interface IProjectConsoleController {

	@ApiOperation(value = "获取全部项目 指标数据", notes = "获取全部项目 指标数据")
	@GetMapping(value = "allProjectIndex")
	public R<AllProjectIndexVO> getAllProjectIndex(
			@ApiParam(value = "接口版本", required = true, defaultValue = VersionConstant.V1) @PathVariable(value = "apiVersion") String apiVersion);
	
	@ApiOperation(value = "项目分期分页列表", notes = "项目分期分页列表")
    @GetMapping(value = "porjectStagePageList")
    public R<List<ProjectOverviewVO>> getPorjectStagePageList(
            @ApiParam(value = "接口版本", required = true, defaultValue = VersionConstant.V1) @PathVariable(value = "apiVersion") String apiVersion,
            @ApiParam(value = "当前第几页", required = true, defaultValue = "1") @RequestParam(value = "current") String current,
            @ApiParam(value = "每页条数", required = true, defaultValue = "2") @RequestParam(value = "pageSize") String pageSize,
            @ApiParam(value = "项目名称或编码", required = false) @RequestParam(name = "projectName", required = false) String projectName);
	
	@ApiOperation(value = "分期版本列表", notes = "获取分期版本列表")
	@GetMapping(value = "stageList")
	public R<List<ProjectVersionVO>> getStageList(
			@ApiParam(value = "接口版本", required = true, defaultValue = VersionConstant.V1) @PathVariable(value = "apiVersion") String apiVersion,
			@ApiParam(value = "分期id", required = true) @RequestParam(name = "stageId",required = true) String stageId);
	
	
	@ApiOperation(value = "获取指定项目 指标数据", notes = "获取指定项目 指标数据")
	@GetMapping(value = "projectIndex")
	public R<ProjectIndexVO> getProjectIndex(
			@ApiParam(value = "接口版本", required = true, defaultValue = VersionConstant.V1) @PathVariable(value = "apiVersion") String apiVersion,
			@ApiParam(value = "项目id", required = true) @RequestParam(name = "projectId",required = true) String projectId);
	
	
	@ApiOperation(value = "获取项目 正在进行列表", notes = "获取项目 正在进行列表")
	@GetMapping(value = "projectUnderwayList")
	public R<List<ProjectUnderwayVO>> getProjectUnderwayList(
			@ApiParam(value = "接口版本", required = true, defaultValue = VersionConstant.V1) @PathVariable(value = "apiVersion") String apiVersion,
			@ApiParam(value = "项目id", required = true) @RequestParam(name = "projectId",required = true) String projectId);
	
}
